const state = {
  adding_folder: false,
  search: '',

  sort: {
    attr: 'name',
    order: -1, //desc:-1 asc:1
  },
  view: 'list',
  nav: []
};

const getters = {

};

const mutations = {
  toggleFolder(state, data) {
    state.adding_folder = data
  },

  saveSearch(state, data) {
    state.search = data
  },
  saveSort(state, data) {
    state.sort = data
  },
  saveView(state, data) {
    state.view = data
  },
  saveNav(state, data) {
    state.nav = data
  }
};

const actions = {

};

export default {
  state,
  getters,
  mutations,
  actions
};